package com.zhuangxiaoyan.springboot.mybatis.domain;

import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.util.Date;

/**
 * Order
 *
 * @author xjl
 * @version 2025/01/11 16:56
 **/

@Data
@EqualsAndHashCode
public class Order {

    /**
     * 订单ID
     */
    private long id;

    /**
     * 用户id
     */
    private String customerId;

    /**
     * 收货地址id
     */
    private String deliveryAddressId;
    /**
     * 订单项ids
     */
    private String orderItemId;
    /**
     * 订单总价
     */
    private BigDecimal totalPrice;

    /**
     * 创建时间
     */
    private Date gmtCreate;
    /**
     * 修改时间
     */
    private Date gmtModify;
    /**
     * 版本号
     */
    private String version;
    /**
     * 扩展信息
     */
    private String extraInfo;

    @Override
    public String toString() {
        return "Order{" +
                "id=" + id +
                ", customerId='" + customerId + '\'' +
                ", deliveryAddressId='" + deliveryAddressId + '\'' +
                ", orderItemId='" + orderItemId + '\'' +
                ", totalPrice=" + totalPrice +
                ", gmtCreate=" + gmtCreate +
                ", gmtModify=" + gmtModify +
                ", version='" + version + '\'' +
                ", extraInfo='" + extraInfo + '\'' +
                '}';
    }
}